class Solution
{
public:
    int countTestedDevices(vector<int> &batteryPercentages)
    {
        int dec = 0;

        for (int b : batteryPercentages)
        {
            if (b > dec)
            {
                dec++;
            }
        }
        return dec;
    }
};